//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop
#include "f_Splash.h"

//---------------------------------------------------------------------------
USEFORM("f_Principal.cpp", frmPrincipal);
USEFORM("f_Sobre.cpp", frmSobre);
USEFORM("f_ListaDuplamenteLigadaStl.cpp", frmListaDuplamenteLigadaStl);
USEFORM("f_Splash.cpp", frmSplash);
USEFORM("f_TabelaStl.cpp", frmTabelaStl);
USEFORM("f_ListaCircularStl.cpp", frmListaCircularStl);
USEFORM("f_ListaLigadaStl.cpp", frmListaLigadaStl);
USEFORM("f_ListaCircularDuplamenteLigadaStl.cpp", frmListaCircularDuplamenteLigadaStl);
USEFORM("f_FilaStl.cpp", frmFilaStl);
USEFORM("f_PilhaStl.cpp", frmPilhaStl);
USEFORM("f_Fila.cpp", frmFila);
USEFORM("f_ListaCircular.cpp", frmListaCircular);
USEFORM("f_ListaCircularDuplamenteLigada.cpp", frmListaCircularDuplamenteLigada);
USEFORM("f_ListaDuplamenteLigada.cpp", frmListaDuplamenteLigada);
USEFORM("f_ListaLigada.cpp", frmListaLigada);
USEFORM("f_Pilha.cpp", frmPilha);
USEFORM("f_Tabela.cpp", frmTabela);
USEFORM("f_ArvoreBinaria.cpp", frmArvoreBinaria);
USEFORM("f_Ordenadores.cpp", frmOrdenadores);
//---------------------------------------------------------------------------
WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
{
	try
	{
		TfrmSplash     * ptr_frmSplash = new TfrmSplash(Application);

		ptr_frmSplash ->Show();
		ptr_frmSplash ->Update();
		Sleep(6000);
		ptr_frmSplash ->Close();
		delete ptr_frmSplash ;
		ptr_frmSplash  = NULL; 

		Application->Initialize();
		SetApplicationMainFormOnTaskBar(Application, true);
		Application->CreateForm(__classid(TfrmPrincipal), &frmPrincipal);
		Application->CreateForm(__classid(TfrmOrdenadores), &frmOrdenadores);
		Application->Run();
	}
	catch (Exception &exception)
	{
		Application->ShowException(&exception);
	}
	catch (...)
	{
		try
		{
			throw Exception("");
		}
		catch (Exception &exception)
		{
			Application->ShowException(&exception);
		}
	}
	return 0;
}
//---------------------------------------------------------------------------
